package com.verisette.ncos.service.master.gateway;

import java.util.List;

import org.corp.agi.common.util.BeanContextFactory;
import org.corp.agi.service.bean.ServiceRequest;
import org.corp.agi.service.bean.ServiceResponse;
import org.corp.agi.service.bizprocess.BusinessProcess;
import com.verisette.ncos.persistence.domain.MasterUserGroup;

/**
 * 
 * {Description here}
 *
 * @author Ratapong Wongpiang (Earth)
 * @since Jul 1, 2010 11:37:09 AM
 * @see
 */
public class RoleManagementServiceImpl implements RoleManagementService {

	@Override
	public ServiceResponse<List<MasterUserGroup>> inquiryUserGroup(ServiceRequest<MasterUserGroup> request) {
		BusinessProcess process = (BusinessProcess) BeanContextFactory.getBean("inquiryUserGroupProcess");
		return process.execute(request);
	}

	@Override
	public ServiceResponse createUserGroup(ServiceRequest<MasterUserGroup> request) {
		BusinessProcess process = (BusinessProcess) BeanContextFactory.getBean("createUserGroupProcess");
		return process.execute(request);
	}

	@Override
	public ServiceResponse<MasterUserGroup> viewUserGroup(ServiceRequest<MasterUserGroup> request) {
		BusinessProcess process = (BusinessProcess) BeanContextFactory.getBean("viewUserGroupProcess");
		return process.execute(request);
	}

	@Override
	public ServiceResponse editUserGroup(ServiceRequest<MasterUserGroup> request) {
		BusinessProcess process = (BusinessProcess) BeanContextFactory.getBean("editUserGroupProcess");
		return process.execute(request);
	}

}
